import { constantRoutes } from '@/router'

// import { asyncRoutes } from '@/router'
export default {
  namespaced: true,
  state: {
    menuRoutes: [...constantRoutes] // 默认将静态路由展开到 vuex
  },
  mutations: {
    getAsyncRoutes(state, filterRoutes) {
      // 这里将从实参获取到的筛选后的当前用户拥有的动态路由权限, 与静态路由一同展开进 一个数组
      state.menuRoutes = [...constantRoutes, ...filterRoutes]
    }
  },
  actions: {

  }
}
